﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using SlimDX;
using SlimDX.Direct3D10;
using System.Windows.Media.Imaging;


namespace EikonLeap
{
    public class SceneObject
    {
        public SceneObject()
        {
            m_objectId = ms_lastObjectId++;
        }

        virtual public void Update(double elapse)
        {
        }

        virtual public Texture2D GetTextureData()
        {
            return null;
        }

        public uint ObjectID
        {
            get
            {
                return m_objectId;
            }
        }

        public virtual bool IntersectScreenSpace(float x, float y, out float d)
        {
            d = 0;
            return false;
        }

        uint m_objectId;
        public Scene m_scene;
        public static uint ms_lastObjectId = 0;
        public Vector3[] Vertices { get; set; }
        public uint[] Indices { get; set; }
        public Vector3[] Normals { get; set; }
        public Vector2[] TexCoord0 { get; set; }
        public Matrix WVP;
        public virtual Matrix GetLocalTransform()
        {
            return Matrix.Identity;
        }
        public bool IsHighlighten { get; set; }
        public bool IsSelected { get; set; }
    }
}
